<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>

<body>

    <div id="app">
        <button @click="add">增加</button>
        <div :key="item.id" v-for="(item,index) in userList">
            <input type="checkbox"> {{index}},{{item.username}},{{item.gender}},{{item.birthday}}
        </div>
    </div>

    <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script>
    <script>
        let vm = new Vue({
            el: '#app',
            data: {
                userList: [
                    { id: 1001, username: 'tom', gender: false, birthday: '2020-1-1' },
                    { id: 1002, username: 'lucy', gender: true, birthday: '2020-11-11' },
                    { id: 1003, username: 'mike', gender: false, birthday: '2020-12-13' },
                    { id: 1004, username: 'ella', gender: true, birthday: '2020-5-6' },
                    { id: 1005, username: 'smith', gender: true, birthday: '2020-5-6' },
                ]
            },
            methods: {
                add() {
                    let user = {
                        id: 1006,
                        username: 'aaa', 
                        gender: true, 
                        birthday: '2020-5-6'
                    };
                    this.userList.unshift(user);
                }
            }
        });
    </script>
</body>

</html>